//
// Created by 高森森 on 2022/1/10.
//

#ifndef LEETCODE_SOLUTION1_H
#define LEETCODE_SOLUTION1_H
#include<iostream>
using namespace std;
#include<vector>

class Solution1 {

public:
    bool validPath(int n, vector<vector<int>>& edges, int start, int end);
    bool validPath2(int n, vector<vector<int>>& edges, int start, int end);
    int find(int x,int fa[]);
    void merge(int i,int j,int fa[],int rank[]);
};



#endif //LEETCODE_SOLUTION1_H
